Fix some nullable Returns annotations
authorDaniel Boles <dboles@src.gnome.org>
Thu, 3 Aug 2017 19:26:18 +0000 (20:26 +0100)
committerDaniel Boles <dboles@src.gnome.org>
Thu, 3 Aug 2017 19:27:29 +0000 (20:27 +0100)
based on reports and patches by Iñaki García Etxebarria:

https://bugzilla.gnome.org/show_bug.cgi?id=781246
https://bugzilla.gnome.org/show_bug.cgi?id=785423

gtk/gtkbin.c
gtk/gtkwidget.c

index 7323d075fa28c8d8cac21fb1aa37e70a62689379..90f2ddea173fd50cd6529c13a1572712fe3a6d87 100644 (file)
@@ -199,7 +199,8 @@ gtk_bin_measure (GtkWidget *widget,
  * no child widget. The returned widget does not have a reference
  * added, so you do not need to unref it.
  *
- * Returns: (transfer none): pointer to child of the #GtkBin
+ * Returns: (transfer none) (nullable): the child of @bin, or %NULL if it does
+ * not have a child.
  **/
 GtkWidget*
 gtk_bin_get_child (GtkBin *bin)
index 5edc2a2a3c13cbd9f7b6182b9433817fb285319c..3f72a7edc40f91f30bc8315568083871cdb982c1 100644 (file)
@@ -9181,9 +9181,10 @@ gtk_widget_set_parent_window (GtkWidget *widget,
  * gtk_widget_get_parent_window:
  * @widget: a #GtkWidget.
  *
- * Gets @widget’s parent window.
+ * Gets @widget’s parent window, or %NULL if it does not have one.
  *
- * Returns: (transfer none): the parent window of @widget.
+ * Returns: (transfer none) (nullable): the parent window of @widget, or %NULL
+ * if it does not have a parent window.
  **/
 GdkWindow *
 gtk_widget_get_parent_window (GtkWidget *widget)